const navbar = [
  { text: 'home', link: '/' },
  { text: 'Vue', link: '/vue/' }, // 内部链接 以docs为根目录
  { text: 'React', link: '/react/' },
  { text: 'Css', link: '/css/' },
  { text: 'Js', link: '/js/' },
  { text: 'TypeScript', link: '/ts/' },
  {
    text: 'Share', children: [
      { text: '表单验证', link: '/share/formValidate/' },
    ]
  },
  {
    text: '技巧', children: [
      { text: 'JS工具函数', link: '/skill/js/' },
      { text: '常用正则', link: '/skill/reg/' },
      { text: 'css高频', link: '/skill/css/' },
    ]
  },
  {
    text: '工具',
    children: [
      { text: 'git备忘录', link: '/tools/git' },
    ]
  },
  // { text: '关于我', link: '/about/' }
]

const sidebar = {
  '/vue/': [
    {
      title: 'Vue',
      collapsable: false,
      children: [
        '/vue/',
        '/vue/vue3.md'
      ]
    }
  ],
  '/react/': [
    {
      title: 'React',
      collapsable: false,
      children: [
        '/react/'
      ]
    }
  ],
  '/css/': [
    {
      title: 'Css',
      collapsable: false,
      children: [
        '/css/'
      ]
    }
  ],
  '/js/': [
    {
      title: '基础',
      collapsable: false,
      children: [
        '/js/',
        '/js/base/type.md',
        '/js/base/array.md',
        '/js/base/others.md'
      ]
    },
    {
      title: '进阶',
      collapsable: false,
      children: [
        '/js/advanced/extends.md',
        '/js/advanced/copy.md',
        '/js/advanced/debounce_throttle.md',
        '/js/advanced/call_apply.md',
        '/js/advanced/proxy.md',
        '/js/advanced/new.md'
      ]
    },
    {
      title: '杂乱',
      collapsable: false,
      children: [
        '/js/merry/unique.md',
        '/js/merry/tool.md',
      ]
    },
    {
      title: '是福不是祸是祸躲不过',
      collapsable: false,
      children: [
        '/js/omg/',
      ]
    }
  ],
  '/ts/': [
    {
      title: 'TypeScript',
      collapsable: false,
      children: [
        '/ts/'
      ]
    }
  ],
  '/tools/': [
    {
      title: '工具',
      collapsable: false,
      children: [
        '/tools/git'
      ]
    },
  ],
  '/skill/': [
    {
      title: '技巧',
      collapsable: false,
      children: [
        '/skill/js/',
        '/skill/reg/',
        '/skill/css/',
      ]
    },
  ],
  '/share/': [
    {
      title: '分享',
      collapsable: false,
      children: [
        '/share/formValidate/',
      ]
    },
  ],
}

module.exports = {
  sidebar,
  navbar
}